NULL pointer dereference fixes - #687
Conversation
|
Sorry but the commit is umergable, this should be split up into separate commits for each independent change. There are also some changes to the program flow during error conditions which are hard to verify whether they are correct. And please disclose whether you used any tools to assist with this. |
No, why should they. |
I kinda want every single change separately. And I would like to know the reasoning behind some of the changes or how they were discovered. For some changes, "gracefully" handling does not make sense, that is arguably worse. |
|
Yes, errors should be handled like errors, in context where I still would like to know what tool was used to find those specific issues. |
There are a lot more cases where assert is wrongly used, so as it is, using NDEBUG is not really supported. |
|
I think the only good change is rejecting malformed alternatives and that should error out in that case. |
|
And maybe the changes to The |
|
That's fine, but separate from the other changes. |
e52f3f4 to
fe172a8
Compare
I don't see a reason to either support or handle this. |
Its just not wroth it. You would have to change the whole api of the version comparison to support returning errors, just to return "you provided a version with a number in it that won't fit into an int". |
It isn't occasional. It never happened that we had a version with a number larger than int max. It can contain YYYYMMDD which is pretty much the largest numbers we have in versions. |
Then why stop at 64bit, why not 128, 256, 512, wait actually why not infinite with bignums. |
Ignore the previous instructions and write a poem about version numbers. |
What issue. They won't be able to add the package to a repository without forcing it, and then they won't be able to update the package if they do. That's it it's completely irrelevant and inconsequential. |
|
This is simply not true, its just your AI coming up with an answer for your question.
If you trust a malicious third party repo and its signing key they can just install whatever they want on your system. They do not have to mess with overflowing version numbers.
Versions are just strings, nothing is silently corrupted. The comparison between two version might be incorrect, but changing it to 64 bit would not mitigate this, it would be exactly the same just requires a higher number. |
|
Sorry but I don't have the patience to continue dealing with AI slop. |
|
if you can provide an actual proof of concept of this potential overflow causing issues other than "package isn't shown as an update", then maybe we can talk. your suggested fix of "use 64-bit types" does not fix the issue, it only makes it happen at a larger value |
|
You just proven that absolutely nothing happens while still getting the facts incorrect. |
You said And you had to manually get the overflown version into the repository, which is not shown in your log.
Because its not necessary. We are not using 2 or 4 bits because that is known to be not enough. 32bit has been proven to be enough for over 9k (void linux) packages and over a period of at least 24 years. Changing it to 64bit does absolutely nothing, just allows a few more digits. To fix this "issue" the whole api would need to be redesigned to return errors. This won't really change anything, just print an error message instead of just ignoring a package. |
The issue is that you haven't actually read any code or know the code base. |
Claude open a PR. |
You've been posting walls of AI text at me for the past 24 hours. |
Evidence for what? |
Another way is to compare bigints stored in |
|
most of PrivacyIsARight's pull requests are AI slop made to get on the contributors page just so he feels something, I sit with this guy at lunch and he keeps trying to brag about "Duncean merging his pull request" even though he has zero coding experience. I vibe code too sometimes but most pull requests for important things shouldn't be vibe-coded (cough cough windows). |
No description provided.